<#include "/common/defaultEngine.html"/>
<@pageTheme mark="${config.optimize()?string('true', 'false')}">
<@header title="新增单范例" bodyClass="white-bg"/>
<div class="wrapper wrapper-content ibox-content">
    <@form.form id="form-test-add"  class="form-horizontal">
    <div class="form-group">
        <label class="col-sm-3 control-label"><@ctx.i18n text = "员工编号"/>：
       </label>
        <div class="col-sm-8"><input name="pin" value="${test.pin?default("")}" class="form-control" type="text" >
        </div>
     </div>
    <div class="form-group">
        <label class="col-sm-3 control-label"><span style="color: red; ">*</span><@ctx.i18n text = "name"/>：
       </label>
        <div class="col-sm-8"><input name="name" value="${test.name?default("")}" class="form-control" type="text"  required>
        </div>
     </div>
    <div class="form-group">
        <label class="col-sm-3 control-label"><@ctx.i18n text = "email"/>：
       </label>
        <div class="col-sm-8"><input name="email" value="${test.email?default("")}" class="form-control" type="text" >
        </div>
     </div>
    <div class="form-group">
        <label class="col-sm-3 control-label"><@ctx.i18n text = "电话"/>：
       </label>
        <div class="col-sm-8"><input name="phone" value="${test.phone?default("")}" class="form-control" type="text" >
        </div>
     </div>
    <div class="form-group">
        <label class="col-sm-3 control-label"><@ctx.i18n text = "性别"/>：</label>
        <div class="col-sm-8">
            <!--  <@form.radio name="sex" dictType="sys_user_sex" value="${test.sex?default('')}" /> -->
            <#list dict.getType('sys_user_sex')>
                <#items as d>
                    <div class="radio-box">
                        <input type="radio" id="sex" name="sex" value="${d.dictValue}"
                               <#if d.dictValue == test.sex?default("") >checked</#if> />
                        <label for="${(d.id)?default('')}">${d.dictLabel}</label>
                    </div>
                </#items>
            </#list>
        </div>
    </div>
    <div class="form-group">
        <label class="col-sm-3 control-label"><@ctx.i18n text = "age"/>：
       </label>
        <div class="col-sm-8"><input name="age" value="${test.age?default("")}" class="form-control" type="text" >
        </div>
     </div>
    <div class="form-group">
        <label class="col-sm-3 control-label"><@ctx.i18n text = "出生日期"/>：</label>
        <div class="col-sm-8">
            <div class="input-group date">
                <span class="input-group-addon"><i class="fa fa-calendar"></i></span>
                <input class="form-control time-input" name="birthday"  data-type="date"   value="${(test.birthday?string('yyyy-MM-dd'))!}" data-format="yyyy-MM-dd" type="text" />
            </div>
        </div>
    </div>
    <div class="form-group">
        <label class="col-sm-3 control-label"><@ctx.i18n text = "education"/>：
       </label>
        <div class="col-sm-8"><input name="education" value="${test.education?default("")}" class="form-control" type="text" >
        </div>
     </div>
    <div class="form-group">
        <label class="col-sm-3 control-label"><@ctx.i18n text = "职位"/>：
       </label>
        <div class="col-sm-8"><input name="position" value="${test.position?default("")}" class="form-control" type="text" >
        </div>
     </div>
    <div class="form-group">
        <label class="col-sm-3 control-label"><@ctx.i18n text = "爱好"/>：
       </label>
        <div class="col-sm-8"><input name="hobby" value="${test.hobby?default("")}" class="form-control" type="text" >
        </div>
     </div>
    <div class="form-group">
        <label class="col-sm-3 control-label"><@ctx.i18n text = "入职日期"/>：</label>
        <div class="col-sm-8">
            <div class="input-group date">
                <span class="input-group-addon"><i class="fa fa-calendar"></i></span>
                <input class="form-control time-input" name="joinDate"  data-type="date"   value="${(test.joinDate?string('yyyy-MM-dd'))!}" data-format="yyyy-MM-dd" type="text" />
            </div>
        </div>
    </div>
    <div class="form-group">
        <label class="col-sm-3 control-label"><@ctx.i18n text = "离职日期"/>：</label>
        <div class="col-sm-8">
            <div class="input-group date">
                <span class="input-group-addon"><i class="fa fa-calendar"></i></span>
                <input class="form-control time-input" name="leaveDate"  data-type="date"   value="${(test.leaveDate?string('yyyy-MM-dd'))!}" data-format="yyyy-MM-dd" type="text" />
            </div>
        </div>
    </div>
    <div class="form-group">
        <label class="col-sm-3 control-label"><@ctx.i18n text = "身份证号"/>：
       </label>
        <div class="col-sm-8"><input name="noationalId" value="${test.noationalId?default("")}" class="form-control" type="text" >
        </div>
     </div>
        <div class="form-group">
                <label class="col-sm-3 control-label"><@ctx.i18n text = "company"/>：</label>
                <div class="col-sm-8">
                      <@form.treeselect id="company"  name="company.id"  value="${(test.company.id)?default('')}"
                        labelValue="${(test.company.name)?default('')}" boxTitle="选择归属公司" url="sys/comp/treeData" expandLevel="true"  placeholder="请选择归属公司"/>
                </div>
            </div>

    <div class="form-group">
        <label class="col-sm-3 control-label"><@ctx.i18n text = "删除标记"/>：
       </label>
        <div class="col-sm-8"><input name="delFlag" value="${test.delFlag?default("")}" class="form-control" type="text" >
        </div>
     </div>
    <div class="form-group">
        <label class="col-sm-3 control-label"><@ctx.i18n text = "备注信息"/>：
       </label>
        <div class="col-sm-8"><input name="remark" value="${test.remark?default("")}" class="form-control" type="text" >
        </div>
     </div>
</@form.form>
</div>
<@footer>
    <script type="text/javascript">
        var prefix = baseURL + "gen/test"
        $("#form-test-add").validate({
            focusCleanup: true
        });

        function submitHandler() {
            if (opt.validate.form()) {
                opt.operate.save(prefix + "/add", $('#form-test-add').serialize());
            }
        }





















</script>
</@footer>
</@pageTheme>